<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        ul{
            list-style: none;
        }
        .carousel{
            position: relative;
            top:0;
            width: 600px;
            height: 360px;
            border: 1px solid #ccc;
            margin:100px auto;
        }
        .carousel ul li{
            position: absolute;
            top: 0;
            left: 0;
            width: 150px;
            height: 360px;
            transform-style: preserve-3d;
            transition: all 0.5s ease 1s;
        }
        .carousel ul li:nth-child(1){
            left: 0;
            
        }
        .carousel ul li:nth-child(2){
            left: 150px;
            
        }
        .carousel ul li:nth-child(3){
            left: 300px;
            
        }
        .carousel ul li:nth-child(4){
            left: 450px;
            
        }
        .carousel ul li div{
            position: absolute;
            top: 0;
            left: 0;
            width: 150px;
            height: 360px;
            background-size: 600px 360px;
        }
        .carousel ul li div:nth-child(1){
            background-image: url("image/pic1.jpg");
            transform: rotateX(0deg) translateZ(180px);
        }
        .carousel ul li div:nth-child(2){
            background-image: url("image/pic2.jpg");
            transform: rotateX(90deg) translateZ(180px);
        }
        .carousel ul li div:nth-child(3){
            background-image: url("image/pic3.jpg");
            transform: rotateX(180deg) translateZ(180px);
        }
        .carousel ul li div:nth-child(4){
            background-image: url("image/pic4.jpg");
            transform: rotateX(270deg) translateZ(180px);
        }
        .carousel ul li:nth-child(1) div{
            background-position: 0 0;
        }
        .carousel ul li:nth-child(2) div{
            background-position: -150px 0;
        }
        .carousel ul li:nth-child(3) div{
            background-position: -300px 0;
        }
        .carousel ul li:nth-child(4) div{
            background-position: -450px 0;
        }
    </style>
</head>
<body>
    <div class="carousel">
       <ul>
           <li>
               <div></div>
               <div></div>
               <div></div>
               <div></div>
           </li>
           <li>
               <div></div>
               <div></div>
               <div></div>
               <div></div>
           </li>
           <li>
               <div></div>
               <div></div>
               <div></div>
               <div></div>
           </li>
           <li>
               <div></div>
               <div></div>
               <div></div>
               <div></div>
           </li>
       </ul>
    </div>
    <input type="button" value="下一张" class="btn">
    <script src="lib/jquery-3.3.1.min.js"></script>
    <script>
        var btn = $(".btn");
        var lis = $(".carousel ul li");

        var sub = 0;
        btn.click(function(){
            sub -= 90;
            lis.css({
                "transform":"rotateX("+sub+"deg)"
            });
        });
    </script>
</body>
</html>